package com.ruoyi.yipaiju.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.yipaiju.mapper.DiscountHouseSigningorderMapper;
import com.ruoyi.yipaiju.domain.DiscountHouseSigningorder;
import com.ruoyi.yipaiju.service.IDiscountHouseSigningorderService;

/**
 * fo_discount_house_signingorderService业务层处理
 * 
 * @author liuwp
 * @date 2023-03-01
 */
@Service
public class DiscountHouseSigningorderServiceImpl implements IDiscountHouseSigningorderService 
{
    @Autowired
    private DiscountHouseSigningorderMapper discountHouseSigningorderMapper;

    /**
     * 查询fo_discount_house_signingorder
     * 
     * @param id fo_discount_house_signingorder主键
     * @return fo_discount_house_signingorder
     */
    @Override
    public DiscountHouseSigningorder selectDiscountHouseSigningorderById(Long id)
    {
        return discountHouseSigningorderMapper.selectDiscountHouseSigningorderById(id);
    }

    /**
     * 查询fo_discount_house_signingorder列表
     * 
     * @param discountHouseSigningorder fo_discount_house_signingorder
     * @return fo_discount_house_signingorder
     */
    @Override
    public List<DiscountHouseSigningorder> selectDiscountHouseSigningorderList(DiscountHouseSigningorder discountHouseSigningorder)
    {
        return discountHouseSigningorderMapper.selectDiscountHouseSigningorderList(discountHouseSigningorder);
    }

    @Override
    public List<DiscountHouseSigningorder> selectDiscountHouseSigningorderList1(DiscountHouseSigningorder discountHouseSigningorder)
    {
        return discountHouseSigningorderMapper.selectDiscountHouseSigningorderList1(discountHouseSigningorder);
    }

    /**
     * 根据业务主键查询一条记录：fo_discount_house_signingorder
     *
     * @param discountHouseSigningorder fo_discount_house_signingorder
     * @return fo_discount_house_signingorder
     */
    @Override
    public DiscountHouseSigningorder selectOneDiscountHouseSigningorder(DiscountHouseSigningorder discountHouseSigningorder)
    {
        return discountHouseSigningorderMapper.selectOneDiscountHouseSigningorder(discountHouseSigningorder);
    }

    /**
     * 新增fo_discount_house_signingorder
     * 
     * @param discountHouseSigningorder fo_discount_house_signingorder
     * @return 结果
     */
    @Override
    public int insertDiscountHouseSigningorder(DiscountHouseSigningorder discountHouseSigningorder)
    {
        discountHouseSigningorder.setCreateTime(DateUtils.getNowDate());
        return discountHouseSigningorderMapper.insertDiscountHouseSigningorder(discountHouseSigningorder);
    }

    /**
     * 修改fo_discount_house_signingorder
     * 
     * @param discountHouseSigningorder fo_discount_house_signingorder
     * @return 结果
     */
    @Override
    public int updateDiscountHouseSigningorder(DiscountHouseSigningorder discountHouseSigningorder)
    {
        discountHouseSigningorder.setUpdateTime(DateUtils.getNowDate());
        return discountHouseSigningorderMapper.updateDiscountHouseSigningorder(discountHouseSigningorder);
    }

    @Override
    public int updateDiscountHouseSigningorderCondition(DiscountHouseSigningorder discountHouseSigningorder, DiscountHouseSigningorder discountHouseSigningorderCondition)
    {
                discountHouseSigningorder.setUpdateTime(DateUtils.getNowDate());
        return discountHouseSigningorderMapper.updateDiscountHouseSigningorderCondition(discountHouseSigningorder, discountHouseSigningorderCondition);
    }

    /**
     * 批量删除fo_discount_house_signingorder
     * 
     * @param ids 需要删除的fo_discount_house_signingorder主键
     * @return 结果
     */
    @Override
    public int deleteDiscountHouseSigningorderByIds(Long[] ids)
    {
        return discountHouseSigningorderMapper.deleteDiscountHouseSigningorderByIds(ids);
    }

    /**
     * 删除fo_discount_house_signingorder信息
     * 
     * @param id fo_discount_house_signingorder主键
     * @return 结果
     */
    @Override
    public int deleteDiscountHouseSigningorderById(Long id)
    {
        return discountHouseSigningorderMapper.deleteDiscountHouseSigningorderById(id);
    }

    /**
     * 条件删除fo_discount_house_signingorder
     *
     * @param discountHouseSigningorder fo_discount_house_signingorder
     * @return 结果
     */
    @Override
    public int deleteDiscountHouseSigningorderByCondition(DiscountHouseSigningorder discountHouseSigningorder)
    {
        return discountHouseSigningorderMapper.deleteDiscountHouseSigningorderByCondition(discountHouseSigningorder);
    }

}
